. .

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Hi everyone,

    Some of you will have noticed regular periods where the forum has become completely inaccessible, throwing up database errors like "Unable to connect to database" and/or similar. I wanted to take a moment to explain what’s been going on behind the scenes for quite some time now and what I’ve done to get things back on track.



    The Problem: Session Table Overload

    The issue has been caused by the session table in our forum's database becoming completely full.

    When you visit the forum, your session (your presence) is logged in that table, it’s what keeps you logged in and tracks general activity. The problem is when that table fills up, new visitors can’t be logged, and as a result, the database throws an error and the forum locks up for everyone.

    Now, this wouldn’t usually happen, there’s a maintenance system in place that clears out old session data (specifically sessions that are over 1 hour old). But here’s the catch…



    Why This Keeps Happening

    The vBulletin forum software doesn’t run its scheduled tasks in the same way a server like Windows or Linux does.

    Instead, vBulletin relies on a kind of "pseudo-cron" system, Basically, every time someone visits the site, a little bit of code in the page footer quietly triggers the task manager in the background (server side).

    That manager then checks what scheduled tasks need to run. Some tasks are set to run daily, some hourly, and some like the one that clears the session table, depend on frequent human visits to keep up.

    But when the site is quiet… those tasks fall behind.
    Fewer visitors = fewer chances for the system to clean itself. So over time, the session table gets full — and then we’re locked out again.



    Fixes Implemented

    I've now taken two key steps to deal with this properly:

    DNS level Managed Challenges

    After investigating the traffic logs, it became clear that we were being flooded with automated traffic, likely bots or abuse scripts, that were swamping the session table by visiting the forum in massive numbers.

    So, I set up Cloudflare’s managed challenge system at DNS level, which in just 24 hours:

    • Blocked or challenged 75,000 visits from Singapore
    • Stopped 45,000 visits from Brazil
    • And filtered out another 75,000+ visits from other parts of Asia

    This has significantly reduced the load and helped prevent the session table from getting hammered.

    Server-Level Scheduled Task (Real Cron)

    I’ve also implemented a proper server-side scheduled task (cron job) that runs independently of site traffic.

    This new task now:

    • Runs on the hour, every hour
    • Clears out any session data older than one hour (if your inactive for this amount of time or more, you will be logged out)
    • Ensures the session table is always kept under control — whether the site is busy or not

    This bypasses the vBulletin system entirely for this particular issue and ensures the session cleanup happens reliably, every time.



    What Happens Next

    These changes should stabilise the forum and keep things running smoothly again. I’ll be continuing to monitor things closely, this has been a long time problem I know, however I’ve got more long-term upgrades coming, including a proper migration to a new platform, I’ll share more on that soon.

    Thanks as always for your patience, and for sticking around. This place is still ticking, and I’m doing everything I can to keep it that way.

    Catch you all soon,
    Lee
    Lee

  2. The Following 3 Users Say Thank You to Lee Roberts For This Useful Post:


Thread Information

Users Browsing this Thread

There are currently 3 users browsing this thread. (0 members and 3 guests)

Similar Threads

  1. NEW MEMBER: anyone with access to CNC machine ?
    By krzysztof1 in forum New Member Introductions
    Replies: 0
    Last Post: 28-10-2021, 06:59 PM
  2. Tool magazine access and the Siemens CNC Sinumerik controls
    By cossiegaz in forum Siemens (Sinumerik)
    Replies: 6
    Last Post: 05-11-2015, 10:14 PM
  3. Mach3 - tutor me via remote access !?
    By ciscoeuk in forum Artsoft Mach (3 & 4)
    Replies: 4
    Last Post: 31-01-2013, 04:57 PM
  4. Recent eBay Ads in the Marketplace - An Explanation
    By blackburn mark in forum Marketplace Discussion
    Replies: 71
    Last Post: 22-07-2012, 12:44 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •